import * as types from './mutation-types'

export default {
  [types.SET_USER_INFO] (state, userInfo) {
    state.userInfo = userInfo;
  },
  [types.SET_TOKEN] (state, token) {
    state.token = token;
  },
  [types.GET_ALL_PHOTOS] (state, photos) {
    state.photos = [].concat(photos);
  },
  [types.SET_PHOTO_SORT] (state, type) {
    state.photoSort = type;
  },
}
